package io.adminboot.repository.extend;

import io.adminboot.repository.SysUserRoleMapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface SysUserRoleExtMapper extends SysUserRoleMapper {

	/**
	 * 查询角色ID
	 * @param userId
	 * @return
	 */
	List<Long> selectRoleIdList(@Param("userId") Long userId);
	
	/**
	 * 删除用户与角色关系
	 * @param userId
	 */
	void deleteByUserId(@Param("userId") Long userId);

	/**
	 * 删除角色ID
	 * @param roleIds
	 * @return
	 */
	int deleteByRoleIds(@Param("roleIds") Long[] roleIds);

}
